import http from "./http.js"
// /api/getcate
const _getcate = () => {
	let options = {
		url:"/api/getcate"
	}
	return http(options)
}
// /api/getbanner 轮播图
const _getbanner = () => {
	let options = {
		url:"/api/getbanner"
	}
	return http(options)
}

// /api/getseckill
const _getseckill = () => {
	let options = {
		url:"/api/getseckill"
	}
	return http(options)
}

// /api/getindexgoods
const _getindexgoods = () => {
	let options = {
		url:"/api/getindexgoods"
	}
	return http(options)
}

// /api/getcates
const _getcates = () => {
	let options = {
		url:"/api/getcates"
	}
	return http(options)
}

// /api/getcategoodPage
const _getcategoodPage = (data={}) => {
	let options = {
		url:"/api/getcategoodPage",
		data
	}
	return http(options)
}

// /api/getgoodsinfo
const _getgoodsinfo = (data={}) => {
	let options = {
		url:"/api/getgoodsinfo",
		data
	}
	return http(options)
}

// /api/sms
const _sms = (data={}) => {
	let options = {
		url:"/api/sms",
		data
	}
	return http(options)
}

// /api/wxlogin
const _wxlogin = (data={}) => {
	let options = {
		url:"/api/wxlogin",
		data
	}
	return http(options)
}

// /api/checktoken
const _checktoken = (header={}) => {
	let options = {
		url:"/api/checktoken",
		header
	}
	return http(options)
}

// /api/cartadd
const _cartadd = (data={},header={}) => {
	let options = {
		url:"/api/cartadd",
		header,
		data
	}
	return http(options)
}

// /api/cartlist
 const _cartlist = (data={},header={}) => {
 	let options = {
 		url:"/api/cartlist",
 		header,
 		data
 	}
 	return http(options)
 }
 
 // /api/cartedit
 const _cartedit = (data={},header={}) => {
 	let options = {
 		url:"/api/cartedit",
 		header,
 		data
 	}
 	return http(options)
 }

// /api/cartdelete
 const _cartdelete = (data={},header={}) => {
 	let options = {
 		url:"/api/cartdelete",
 		header,
 		data
 	}
 	return http(options)
 }
 
 // /api/orderadd
 const _orderadd = (data={},header={}) => {
 	let options = {
 		url:"/api/orderadd",
		data,
 		header
 		
 	}
 	return http(options)
 }
 
 // /api/search
 const _search = (data={}) => {
 	let options = {
 		url:"/api/search",
 		data
 	}
 	return http(options)
 }
 
 // /api/orders
 const _orders = (data={},header={}) => {
 	let options = {
 		url:"/api/orders",
 		data,
 		header
 		
 	}
 	return http(options)
 }
export default {
	_getcate,_getbanner,_getseckill,_getindexgoods,_getcates,
	_getcategoodPage,_getgoodsinfo,_sms,_wxlogin,_checktoken,_cartadd,
	_cartlist,_cartedit,_cartdelete,_orderadd,_search,_orders
	
}